package com.dzu.gulimall.product.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.dzu.gulimall.product.entity.AttrGroupEntity;
import com.dzu.gulimall.product.vo.SpuItemAttrGroupVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 属性分组
 *
 * @author zhaodong
 * @email zhaodong@qq.com
 * @date 2021-04-11 20:58:02
 */
@Mapper
public interface AttrGroupDao extends BaseMapper<AttrGroupEntity> {


    /**
     * 查询spu有多少对应的属性分组
     * groupName \ attrName \ attrValue
     * @param spuId
     * @param catalogId
     * @return
     */
    List<SpuItemAttrGroupVo> getAttrGroupWithAttrsBySpuId(@Param("spuId") Long spuId, @Param("catalogId") Long catalogId);
}
